<?php
/*sleep(2);*/
	if (isset($_GET['team'])	 	&& isset($_GET['name_rater']) 	&& isset($_GET['id_group']) 		&& 
		isset($_GET['id_country']) 	&& isset($_GET['date_start']) 	&& isset($_GET['date_end']) 		&& 
		isset($_GET['type'])		&& ($_GET['type'] == 'nb' || $_GET['type'] == 'moy')				&&
		$_GET['date_start'] != ''	&& $_GET['date_end'] != '')
	{
		require_once('Class/reporting.Class.php');

		$report = new reporting();
		
		$report->getNbAverage($_GET);
	}
	if (isset($_GET['type']) 			&& isset($_GET['date_start']) 	&& isset($_GET['date_end']) && isset($_GET['team']) &&
		$_GET['type'] == 'over_under' 	&& $_GET['date_start'] != '' 	&& $_GET['date_end'] != '' 	&& $_GET['team'] != '')
	{
		require_once('Class/reporting.Class.php');

		$report = new reporting();
		
		$report->getOverFifty($_GET);
	}

	if (isset($_GET['team'])	 	&& isset($_GET['name_rater']) 		&& isset($_GET['id_group']) 		&& 
		isset($_GET['id_country']) 	&& isset($_GET['date_start']) 		&& isset($_GET['date_end']) 		&& 
		isset($_GET['type'])		&& ($_GET['type'] == 'repartition')	&&
		$_GET['date_start'] != ''	&& $_GET['date_end'] != '')
	{
		require_once('Class/reporting.Class.php');

		$report = new reporting();
		$report->countDistribution($_GET);
	}

	if (isset($_GET['type']) 			&& isset($_GET['date_start']) 		&& isset($_GET['date_end']) && 
		isset($_GET['consultant_name']) && $_GET['type'] == 'table_average')
	{
		require_once('Class/reporting.Class.php');

		$report = new reporting();
		$report->getAverageMarkByGroup($_GET);
	}

	if (isset($_GET['type']) 			&& isset($_GET['date_start']) 		&& isset($_GET['date_end']) && 
		isset($_GET['consultant_name']) && $_GET['type'] == 'table_average_nb')
	{
		require_once('Class/reporting.Class.php');

		$report = new reporting();
		$report->getNbRating($_GET);
	}

	if (isset($_GET['type']) 			&& isset($_GET['date_start']) 		&& isset($_GET['date_end']) 	&&
		isset($_GET['id_group']) 		&& isset($_GET['consultant_name']) 	&& isset($_GET['id_country']) 	&& 
		$_GET['type'] == 'table_average_criteria' && isset($_GET['team']) 	&& isset($_GET['name_rater'])		)
	{
		require_once('Class/reporting.Class.php');

		$report = new reporting();
		$report->getAverageMarkCriteria($_GET);
	}

	if (isset($_GET['type']) 			&& isset($_GET['date_start']) 		&& isset($_GET['date_end']) 	&&
		isset($_GET['id_group']) 		&& isset($_GET['consultant_name']) 	&& isset($_GET['id_country']) 	&& 
		$_GET['type'] == 'table_unacceptable' && isset($_GET['team']) 	&& isset($_GET['name_rater'])		)
	{
		require_once('Class/reporting.Class.php');

		$report = new reporting();
		$report->getNbUnacceptable($_GET);
	}

	if (isset($_GET['type']) && $_GET['type'] == 'table_calibration')
	{
		require_once('Class/reporting.Class.php');

		$report = new reporting();
		$report->getNbCalibration($_GET);
	}

	if (isset($_GET['type']) && $_GET['type'] == 'table_listed_consultant')
	{
		require_once('Class/reporting.Class.php');

		$report = new reporting();
		$report->getListedMarkConsultant($_GET);
	}

	if (isset($_GET['type']) && $_GET['type'] == 'table_criteria_title')
	{
		require_once('Class/reporting.Class.php');

		$report = new reporting();
		$report->getAssociateCriteria($_GET);
	}

	if (isset($_GET['type']) && $_GET['type'] == 'table_criteria_description')
	{
		require_once('Class/reporting.Class.php');

		$report = new reporting();
		$report->getCriteriaMarkByIdCalibration($_GET);
	}

	if (isset($_GET['type']) && $_GET['type'] == 'table_debrief')
	{
		require_once('Class/reporting.Class.php');

		$report = new reporting();
		$report->getNbRejectedDebrief($_GET);
	}
?>